﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;
using WXYW.BLL;
using WXYW.DAL;

namespace WXYW
{
    public partial class ProductHaveSent : System.Web.UI.Page
    {
        protected void Page_Load(object sender, EventArgs e)
        {

        }

        private void BindCustomerInfo()
        {
            ApplicationProductService productService = new ApplicationProductService();
            ApplicationProduct product = productService.GetApplicationProductByID(long.Parse(Request.QueryString[Constants.QUERYSTR_PRODUCT_ID]));
            if (!product.ApplicationFormReference.IsLoaded)
            {
                product.ApplicationFormReference.Load();
            }
            if (!product.ApplicationForm.UserReference.IsLoaded)
            {
                product.ApplicationForm.UserReference.Load();
            }
            applyCompanyNameTxtBox.Text = product.ApplicationForm.User.FullName;
            mailAddressTxtBox.Text =  product.ApplicationForm.User.UserAddress;
            applierEmailTxtBox.Text =  product.ApplicationForm.User.UserEmail;
            applierFaxTxtBox.Text =  product.ApplicationForm.User.UserFax;
            applierMobilePhoneTxtBox.Text =  product.ApplicationForm.User.UserMobilePhone;
            applierNameTxtBox.Text =  product.ApplicationForm.User.ContactPerson;
            applierPhoneTxtBox.Text =  product.ApplicationForm.User.UserPhone;
        }
    }
}
